package admin.common.constant;

/**
 * 权限相关常量定义
 * Created by zgb on 2020/6/19.
 */
public interface AuthConstant {

    String JTI_KEY = "jti";


    /**
     * JWT存储权限前缀
     */
    String AUTHORITY_PREFIX = "ROLE_";

    /**
     * JWT存储权限属性
     */
    String AUTHORITY_CLAIM_NAME = "authorities";


    /**
     * Redis缓存权限规则key
     */
    String RESOURCE_ROLES_MAP_KEY = "auth:resourceRolesMap";

    /**
     * 认证信息Http请求头
     */
    String JWT_TOKEN_HEADER = "Authorization";

    /**
     * JWT令牌前缀
     */
    String JWT_TOKEN_PREFIX = "Bearer ";


    /**
     * token黑名单redis key
     */
    String TOKEN_BLACKLIST_PREFIX = "auth:token:blackList:";

    /**
     * token会话列表redis key
     */
    String TOKEN_SESSIONLIST_PREFIX = "auth:token:sessionList:";
    String FEISHU_TENANTACCESSTOKEN_PREFIX = "feishu:tenantAccessToken";
    String FEISHU_APPACCESSTOKEN_PREFIX = "feishu:appAccessToken";
    String FEISHU_USERACCESSTOKEN_PREFIX = "feishu:userAccessToken";
    String FEISHU_LOGIN_ADMINID_PREFIX = "feishu:login:adminId";
    String TOKEN_STORE_PREFIX = "oauth:";


}
